package com.bonc.rms.dao.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.bonc.rms.dao.OrderDao;
import com.bonc.rms.mapper.OrderMapper;

@Repository(value = "orderDaoImpl")
public class OrderDaoImpl implements OrderDao{
	@Autowired
	OrderMapper orderMapper;

	@Override
	public List<Map<String, Object>> getOrderInfo() {
		return orderMapper.getOrderInfo();
	}

	@Override
	public List<Map<String, Object>> getSingleOrderInfo(Integer orderId) {
		return orderMapper.getSingleOrderInfo(orderId);
	}

	@Override
	public List<Map<String, Object>> updateOrderInfo(Integer orderId, Integer userId, String petName, String orderCode,
			String itemName, String quantity, String itemPricing, String address) {
		return orderMapper.updateOrderInfo(orderId, userId, petName, orderCode,
				itemName, quantity, itemPricing, address);
	}

	@Override
	public Object deleteOrderInfo(Integer orderId) {
		return orderMapper.deleteOrderInfo(orderId);
	}

}
